<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
        "http://www.w3.org/TR/html4/loose.dtd">
<!--[if IE 8]>
<html lang="en" class="ie8 no-js"> <![endif]-->
<!--[if IE 9]>
<html lang="en" class="ie9 no-js"> <![endif]-->
<!--[if !IE]><!-->
<html lang="en" class="no-js"> <!--<![endif]-->
<!-- BEGIN HEAD -->
<head>
    <include file="Public:meta"/>
</head>
<!-- END HEAD -->
<!-- BEGIN BODY -->
<body class="page-header-fixed">
<include file="Public:header"/>
<!-- BEGIN CONTAINER -->
<div class="page-container">
    <include file="Public:sidebar"/>
    <!-- BEGIN PAGE -->
    <div class="page-content">
        <!-- BEGIN PAGE CONTAINER-->
        <div class="container-fluid">
            <!-- BEGIN PAGE HEADER-->
            <div class="row-fluid">
                <!-- begin BCN -->
                <div class="row-fluid">
                    <div class="span12"><ul class="breadcrumb"><li><i class="icon-home"></i><a onfocus="blurLink(this);" href="{:U('Index/index')}">首页</a>&nbsp;<span class="icon-angle-right"></span>&nbsp;</li><li><a onfocus="blurLink(this);" href="{:U(CONTROLLER_NAME . '/index', 'kept=1')}">{$ParentPageName|default="未命名"}</a>&nbsp;<span class="icon-angle-right"></span>&nbsp;</li><li>{$PageName|default="未命名"}</li></ul></div>
                </div>
                <!-- end BCN -->
            </div>
            <!-- END PAGE HEADER-->
            <!-- BEGIN PAGE CONTENT-->
            <div class="row-fluid white">
                <div class="span12">
                    <!-- begin 操作与分页 -->
                    <div class="row-fluid ">
                        <div class="dataTables_length pull-left">
                            <form id="limit_form" name="limit_form" method="post" action="">
                                <label for="limit_num">
                                    <select class="limit_num" id="limit_num" name="limit_num">
                                    <volist name="page_limit_num" id="vo">
                                        <option <eq name="_SESSION['page_limit_num']" value="$vo"> selected="selected" </eq> value="{$vo}">{$vo}</option>
                                    </volist>
                                    </select>
                                    个记录/每个页面
                                </label>
                            </form>
                        </div>
                        <div class="btn-item pull-left">
                            <if condition="checkAccess(CONTROLLER_NAME, 'save')">
                                <if condition="$_GET['type'] eq 3">
                                    <a class="btn blue" href="{:U(CONTROLLER_NAME.'/save',array('type' => 3))}">添加<i class="icon-plus"></i></a>
                                <else/>
                                    <a class="btn blue" href="{:U(CONTROLLER_NAME.'/save')}">添加<i class="icon-plus"></i></a>
                                </if>
                            </if>
                        </div>
                    </div>
                    <!-- end 操作与分页 -->
                    <div class="portlet-body">
                        <table class="table table-striped table-hover table-bordered">
                            <thead>
                                <tr>
                                    <!-- start批量操作 -->
                                    <notempty name="handle">
                                        <th><input type="checkbox" class="check_all" /></th>
                                    </notempty>
                                    <!-- end批量操作 -->
                                    <volist name="index_content" id="vo">
                                        <th class='hidden-phone sorting <if condition="$_GET['sorting'] eq $vo['field']" >sorting-{$_GET["order"]}</if>' data-status="{$vo.status}" data-sorting="{$vo.field}">{$vo.label}</th>
                                    </volist>
                                    <th>管理操作</th>
                                </tr>
                            </thead>
                            <notempty name="list">
                                <tbody>
                                    <volist name="list" id="vo">
                                        <tr>
                                            <!-- start批量操作 -->
                                            <notempty name="handle">
                                                <td><input type="checkbox" class="check_list" value="{$vo.id}" /></td>
                                            </notempty>
                                            <!-- end批量操作 -->
                                            <volist name="index_content" id="item">
                                                <td class="hidden-phone" data-field="{$key}" data-id="{$vo.id}">
                                                    <!-- start判断是否为图片 -->
                                                    <if condition="$item['field'] eq image">
                                                        <img style="display:inline-block;width:50px;height:50px;" src="{$vo[$item['field']]}" />
                                                    <else/>
                                                        <!-- start判断是否存在关联数据 -->
                                                        <if condition="isset($item['relation'])">
                                                            {$vo[$item['field']]|getTitle=###,$item['relation'][0],$item['relation'][1]}
                                                        <else/>
                                                            {$vo[$item['field']]}
                                                        </if>
                                                        <!-- end判断是否存在关联数据 -->
                                                    </if>  
                                                    <!-- end判断是否为图片 --> 
                                                </td>
                                            </volist>
                                            <td>
                                                <div class="action_btn">
                                                    <div>
                                                        <if condition="checkAccess(CONTROLLER_NAME, 'edit')">
                                                            <a class="btn yellow-stripe mini" href="{:U(CONTROLLER_NAME.'/edit',array('id' => $vo['id']))}">编辑</a>
                                                        </if>
                                                        <if condition="checkAccess(CONTROLLER_NAME, 'del')">
                                                            <a class="btn red-stripe mini del" data-id="{$vo.id}" href="javascript:void(0);">删除</a>
                                                        </if>
                                                    </div>
                                                </div>
                                            </td>
                                        </tr>
                                    </volist>
                                </tbody>
                            </notempty>
                        </table>
                    </div>
                    <div class="pages clearfix">
                        <notempty name="handle">
                            <div class="control-group pull-left">
                                <select class="list_op_type m-wrap">
                                    <volist name="handle" id="vo">
                                        <option value="{$vo.access}">{$vo.label}</option>
                                    </volist>
                                </select>
                                <button class="btn blue list_op">确定</button>
                            </div>
                        </notempty>
                        <include file="Public:page" />
                    </div>
                </div>
            </div>
            <!-- END PAGE CONTENT-->
        </div>
        <!-- END PAGE CONTAINER-->
    </div>
    <!-- END PAGE -->
</div>
<!-- END CONTAINER -->

<include file="Public:footer"/>
<script type="text/javascript">
    jQuery(document).ready(function () {

    });
</script>
<!-- END JAVASCRIPTS -->
</body>
<!-- END BODY -->
</html>